/*
 * Robot.h
 *
 *  Created on: Feb 19, 2011
 *      Author: Anton
 */

#ifndef ROBOT_H_
#define ROBOT_H_

#define LEGS 4
#define ROBOTMASS 160

#include "Leg.h"
#include <vector>
#include <string>
#include <iostream>
#include <fstream>
using std::vector;
using std::endl;
using std::cout;
using namespace std;

class Robot {
public:
	Robot();
	virtual ~Robot();
    double getHeight() const;
    double getLength() const;
    double getSpeedWait() const;
    double getOldspeed() const;
    double getSpeed() const;
    double getWidth() const;
    double getX() const;
    double getY() const;
    double getZ() const;
    double getMass() const;
    void setMass(double mass);
    void setHeight(double height);
    void setLength(double length);
    void setOldspeed(double oldspeed);
    void setSpeed(double speed);
    void setWidth(double width);
    void setX(double x);
    void setY(double y);
    void setZ(double z);
    void setSpeedWait(double sw);
    void printInfo();
    double getHl() const;
    void setHl(double hl);
    double getBl() const;
    double getFl() const;
    double getVl() const;
    void setBl(double bl);
    void setFl(double fl);
    void setVl(double vl);
    int getOrientation() const;
    void setOrientation(int orientation);
    Leg* legs;
    Matrix forwardK();
    void inverseK();
    void printIK();
    void logIK();
    Matrix calcCG();

private:
    int logbool;
	double x;
	double y;
	double z;
	double speed;
	double oldspeed;
	double width;
	double length;
	double height;
	int orientation;
	double mass;
	double fl;
	double bl;
	double vl;
	double hl;
	double speedwait;
	Matrix CGXYZ;
};	

#endif
